package com.bestcem.xm.qdes.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.bestcem.xm.component.mybatis.base.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

@Data
@EqualsAndHashCode(callSuper = true)
@TableName(value = "ds_qdes_publish")
public class QdesPublish extends BaseEntity {

    @TableId(value = "id")
    private String id;

    /**
     * 租户id
     */
    @TableField(value = "org_id")
    private String orgId;

    /**
     * 规则名称
     */
    @TableField(value = "name")
    private String name;

    /**
     * 分享对象的类型
     */
    @TableField(value = "ttype")
    private Integer ttype;

    /**
     * 分享对象为账号时。对应的账号id
     */
    @TableField(value = "user_id")
    private String userId;

    /**
     * 分享对象为组织时，对应的组织id
     */
    @TableField(value = "region_id")
    private String regionId;

    /**
     * 分享对象为组织时，对应的组织层级id
     */
    @TableField(value = "region_type_id")
    private String regionTypeId;

    /**
     * 被分享的问卷id
     */
    @TableField(value = "project_id")
    private String projectId;

    /**
     * 权限列表
     */
    @TableField(value = "permission_arry")
    private String permissionArry;

    /**
     * 权限类型
     */
    @TableField(value = "permission_type")
    private Integer permissionType;
}